@echo off
chcp 65001 >nul
echo 测试分销员管理API修复

echo.
echo 1. 测试无效参数 "undefined"
curl -X GET "http://localhost:8080/api/admin/distributor/undefined" ^
  -H "Content-Type: application/json" ^
  -w "状态码: %%{http_code}\n"

echo.
echo 2. 测试空参数
curl -X GET "http://localhost:8080/api/admin/distributor/" ^
  -H "Content-Type: application/json" ^
  -w "状态码: %%{http_code}\n"

echo.
echo 3. 测试负数ID
curl -X GET "http://localhost:8080/api/admin/distributor/-1" ^
  -H "Content-Type: application/json" ^
  -w "状态码: %%{http_code}\n"

echo.
echo 4. 测试有效ID
curl -X GET "http://localhost:8080/api/admin/distributor/1" ^
  -H "Content-Type: application/json" ^
  -w "状态码: %%{http_code}\n"

echo.
echo 5. 测试佣金明细API - 无效参数
curl -X GET "http://localhost:8080/api/admin/distributor/undefined/commission-details" ^
  -H "Content-Type: application/json" ^
  -w "状态码: %%{http_code}\n"

echo.
echo 6. 测试佣金明细API - 有效参数
curl -X GET "http://localhost:8080/api/admin/distributor/1/commission-details" ^
  -H "Content-Type: application/json" ^
  -w "状态码: %%{http_code}\n"

echo.
echo 测试完成
pause 